<?php
header('content-type:text/html; charset=utf-8');
?>
			
<html>
<head>
<title>点餐系统编写</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="css/bootstrap.min.css" rel="stylesheet">
<script src="js/jquery-1.11.1.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<!--[if lt IE 9]>
<script src="js/html5shiv.js"></script>
<script src="js/respond.min.js"></script>
<![endif]-->
</head>
<body>
<div class="container">
<div class="row">
<div class="col-xs-offset-4 col-md-5 col-lg-6">
<div class="modal-content">
<div class="modal-header">
<div class="modal-title">
<h3>提示</h3>
</div>			
</div>

			<?php 
					header('content-type:text/html; charset=utf-8');
					@$id=$_REQUEST['id'];
					$pdo=new PDO ('mysql:dbname=mk;charset=utf8','root');
					$sql=$pdo->prepare('delete from picture where typeId=:id;
										delete from type where id=:id');
					$mg="";
					if($sql->execute(array('id'=>$id))){
						
					header('Refresh:2;url=dishTypeList.php');
					$mg=('删除成功！');
					}
					?>
					
					<div class="modal-body">
					<?php echo $mg;?>
					</div>
					<div class="modal-footer">
					<a href="dishTypeList.php" class="btn btn-default">确定</a>
					</div>
					</div>



</div>
</div>
</div>
</body>
</html>